package com.shangcheng.dubbo.api;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import com.shangcheng.dubbo.mappers.UmsMemberLevelMapper;
import com.shangcheng.model.domain.UmsMemberLevel;
import org.apache.dubbo.config.annotation.DubboService;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.util.ObjectUtils;

import java.util.List;

/**
 * @author shiqiang
 * @version 1.0
 * @date 2022/5/13 22:33
 */
@DubboService
public class UmsMemberLevelApiImpl implements UmsMemberLevelApi{
    @Autowired
    private UmsMemberLevelMapper umsMemberLevelMapper;
    @Override
    public List<UmsMemberLevel> memberLevelList(Integer defaultStatus) {
        LambdaQueryWrapper<UmsMemberLevel> wrapper= new LambdaQueryWrapper<>();
        wrapper.eq(UmsMemberLevel::getDefaultStatus,defaultStatus);
       return umsMemberLevelMapper.selectList(wrapper);
    }
}
